/* Name:	Rio Atmadja
   Program:	queue_array.h
*/

#ifndef QUEUEARRAY_H
#define QUEUEARRAY_H
#include<iostream>
using namespace std;

template <class Type>
class queue_array {

	private:
		int front; //this variable points to the front element of the queue
		int back; //this variable point to the back element of the queue
		int size; //this variable keeps track the size of the queue
		int MAXSIZE; //this variable keeps the Maximum zise of the queue
		Type *list; //pointer to the array that holds the queue elements

	public:
		queue_array(); //default constractor
		~queue_array(); //default destractor
		bool empty(); //check if the queue is empty 
		bool full(); //check wheter the queue is full or not	
		void push(Type); //push data into the queue
		void pop(); //delete an element from the queue
		int length(); //return the length of the queue
		void print(); //print the queue
		Type first(); //return the front element
		Type last(); //return the back element
		void shuffle(); //shuffle the queue	
		void print_to_file(); //print to a file
};
#include "queue_array.cpp"
#endif













